--[[

			Turrets

]]--

TURRETS = {}
TURRETS.AllTurrets = {}

function TURRETS:AddTurret(info)
	i = 1
	for _, t in pairs(TURRETS.AllTurrets) do
		if string.find(t.ID, base.ID) then i = i + 1 end
	end
	
	info.ID = base.ID .. i
	info.Icon = base.Icon .. i
	info.Level = i
	info.Title = base.Title
	info.Model = base.Model
	info.ENT = base.ENT
	
	TURRETS.AllTurrets[info.ID] = info
end


-- Gun Turret
	-- Base	
	base = { ID = "atg", Title = "Gun Turret", ENT = "adv_turret_gun",
			 Model = "models/Combine_turrets/Floor_turret.mdl", Icon = "icon_GunTurret" }

	-- Level 1
	TURRETS:AddTurret(	{ Unlocked = 1, UnlockItem = nil, Cost = 250, Damage = 5, Range = 200, FireDelay = 1.2 }	)
	
	-- Level 2
	TURRETS:AddTurret(	{ Unlocked = 0, UnlockItem = "someItemCode", Cost = 350, Damage = 12, Range = 410, FireDelay = 0.9 }	)
	
	-- Level 3
	TURRETS:AddTurret(	{ Unlocked = 0, UnlockItem = "someOtherItemCode", Cost = 600, Damage = 23, Range = 560, FireDelay = 0.55 }	)
	
	-- Level 4
	TURRETS:AddTurret(	{ Unlocked = 0, UnlockItem = "someOtherItemCode", Cost = 1050, Damage = 11, Range = 800, FireDelay = 0.15 }	)



-- Fire Turret
	-- Base	
	base = { ID = "atf", Title = "Fire Turret", ENT = "adv_turret_fire",
			 Model = "models/Combine_turrets/Floor_turret.mdl", Icon = "icon_FireTurret" }
			 
	-- Level 1
	TURRETS:AddTurret(	{ Unlocked = 1, UnlockItem = nil, Cost = 400, Damage = 1, Strength = 5, BurnTime = 3, Range = 100, FireDelay = 0.1	} )
	
	-- Level 2	
	TURRETS:AddTurret(	{ Unlocked = 0, UnlockItem = "fst", Cost = 750, Damage = 2, Strength = 8, BurnTime = 6, Range = 230, FireDelay = 0.1	} )
	